﻿using Bilibili.Common.Api;
using Bilibili.Model.Common;
using Bilibili.WebClient.Common;
using System.Text;

namespace Bilibili.WebClient
{
    public abstract class ClientBase: ApiClientBase
    {
        protected override IApiClient ApiClient => Current.Instance.ApiClient;
        protected override string GetSignUrl(string original, ApiKeyInfo apiKeyInfo = null)
        {
            StringBuilder stringBuilder = new StringBuilder(original);
            stringBuilder.Append($"&sign={ApiProvider.Instance.GetSign(original, apiKeyInfo)}");
            return stringBuilder.ToString();
        }
    }
}